//
//  WatchAddRequestData.m
//  Kids
//
//  Created by LiTengFei on 14/11/26.
//  Copyright (c) 2014年 90's Technology Co.Ltd. All rights reserved.
//

#import "WatchAddRequestData.h"

@implementation WatchAddRequestData
- (instancetype)init
{
    if (self = [super init]) {
        self.r = @"watch/add";
    }
    return self;
}

- (NSDictionary*)data
{
    self.imei = self.imei==nil?@"":self.imei;
    self.pphone = self.pphone==nil?@"":self.pphone;
    self.ppassword = self.ppassword==nil?@"":self.ppassword;
    self.wphone = self.wphone==nil?@"":self.wphone;
    self.name = self.name==nil?@"":self.name;
    self.password = self.password==nil?@"":self.password;
    self.image = self.image ==nil?@"":self.image;
    
    NSParameterAssert(self.imei);
    NSParameterAssert(self.pphone);
    NSParameterAssert(self.ppassword);
    NSParameterAssert(self.wphone);
    NSParameterAssert(self.name);
    NSParameterAssert(self.password);
    NSParameterAssert(self.image);

    return @{
        @"imei" : self.imei,
        @"pphone" : self.pphone,
        @"ppwd" : self.ppassword,
        @"wphone" : self.wphone,
        @"name" : self.name,
        @"pwd" : self.password,
        @"image" : self.image
    };
}
@end
